<template>
  <div>
    <div class="list">
      <!--   <InfoItem :infoItem="info[0]" />
      <InfoItem :infoItem="info[1]" />
      <InfoItem :infoItem="info[2]" />
      <InfoItem :infoItem="info[3]" />-->
      <InfoItem
        v-for="(item,index) in info"
        :key="index"
        :infoItem="info[index]"
        @get_item_id="get_item_id"
      />
    </div>
  </div>
</template>

<script>
import InfoItem from "./InfoItem";
export default {
  name: "InfoList",
  props: ["info"],
  data() {
    return {};
  },

  components: {
    InfoItem
  },

  computed: {},

  beforeMount() {},

  mounted() {},

  methods: {
    get_item_id(item_id) {
      console.log("infolist");
      console.log(item_id);
      this.$emit("getId", item_id);
    }
  },

  watch: {}
};
</script>
<style>
.list {
  display: flex;
  justify-content: space-around;
}
</style>